/* 抓包规则 */
import request from '@/utils/request';

// 查询探针数据过滤信息
export function getProbeDataFilter(query: any): ApiPromise<ApiResponse> {
	return request({
		url: '/management/probeDataFilter',
		method: 'post',
		data: query,
	});
}

// 查询探针数据过滤信息
export function getProbeDataFilterById(id: any): ApiPromise<ApiResponse> {
	return request({
		url: '/management/probeDataFilter/' + id,
		method: 'get',
	});
}

// 添加探针数据过滤信息
export function addProbeDataFilter(data: any): ApiPromise<ApiResponse> {
	return request({
		url: '/management/probeDataFilter/save',
		method: 'post',
		data: data,
	});
}

// 修改探针数据过滤信息
export function updateProbeDataFilter(data: any): ApiPromise<ApiResponse> {
	return request({
		url: '/management/probeDataFilter',
		method: 'put',
		data: data,
	});
}

// 删除探针数据过滤信息
export function delProbeDataFilter(ids: any): ApiPromise<ApiResponse> {
	return request({
		url: '/management/probeDataFilter/delete/' + ids,
		method: 'delete',
	});
}

// 开始同步探针数据过滤信息
export function startSynFilterData(data: any): ApiPromise<ApiResponse> {
	return request({
		url: '/management/probeDataFilter/startSynFilterData',
		method: 'post',
		data: data,
	});
}

// 停止抓包
export function stop(ids: any): ApiPromise<ApiResponse> {
	return request({
		url: '/management/probeDataFilter/stop/' + ids,
		method: 'delete',
	});
}
